<template>
    <el-row :gutter="20" class="main-row">
      <!-- 左侧的列 -->
      <el-col :span="4" class="leftside-col">
          <div  v-for="item in areaList">
            <el-card shadow="always" class="leftclass">
              <LeftSideCard :area_id="item.area" :area_value="item.area_value" :area_unit="item.area_unit"
                :monitor_value="item.monitor_value" :warning_value="item.warning_value"></LeftSideCard>
            </el-card>
          </div>
        
      </el-col>

      <el-col :span="20" class="rightside-col">
        <el-row :gutter="20" style="height:15%" type="flex" align="middle">
          <el-col :span="12">
            <div style="text-align:center">
              <img :src="require('@/assets/trackingimg/BatchParameter1.png')" alt="picture1" width="70%">
            </div>
          </el-col>
          <el-col :span="3">
            <div style="text-align:center;height:100px;">
              <img :src="require('@/assets/trackingimg/BatchParameter2.png')" alt="picture2" width="100%" height="100%">
            </div>
          </el-col>
          <el-col :span="3">
            <div style="text-align:center;height:100px;">
              <img :src="require('@/assets/trackingimg/BatchParameter3.png')" alt="picture3" width="100%" height="100%">
            </div>
          </el-col>
          <el-col :span="3">
            <div style="text-align:center;height:100px;">
              <img :src="require('@/assets/trackingimg/BatchParameter4.png')" alt="picture4" width="100%" height="100%">
            </div>
          </el-col>
          <el-col :span="3">
            <div style="text-align:center;height:100px;">
              <img :src="require('@/assets/trackingimg/BatchParameter5.png')" alt="picture5" width="100%" height="100%">
            </div>
          </el-col>
        </el-row>
        <!-- 表1 -->
        <el-row style="height:41%;margin-top:10px;" :gutter="20" type="flex" align="middle">
          <el-col :span="12">
            <el-card shadow="always">
              <BatchTable1></BatchTable1>
            </el-card>
          </el-col>
        <!-- 表2 -->
          <el-col :span="12">
            <el-card shadow="always">
              <BatchTable2></BatchTable2>
            </el-card>
          </el-col>
        </el-row>

        <el-row style="height:42%;margin-top:10px;" :gutter="20" type="flex" align="middle">
        <!-- 表3 -->
          <el-col :span="12">
            <el-card shadow="always">
              <BatchTable3></BatchTable3>
            </el-card>
          </el-col>
          <!-- 右下角进度条 -->
          <el-col :span="12" class="right-buttom-col">
            <el-card shadow="always">
              <div v-for="item2 in lineList" style="margin-top:7px" @click="toAreaLineOverview()">
                <BatchProgress :line_name="item2.line_name" :lmonitor_value="item2.monitor_value"
                  :lwarning_value="item2.warning_value" :lpro_percent="item2.pro_percent"></BatchProgress>
              </div>
            </el-card>
          </el-col>
        </el-row>
      </el-col>
    </el-row>
</template>
<script>
  import LeftSideCard from "@/pages/contents/tracking/BatchParameterPages/subComponents/LeftSideCard";
  import BatchTable1 from "@/pages/contents/tracking/BatchParameterPages/subComponents/BatchTable1";
  import BatchTable2 from "@/pages/contents/tracking/BatchParameterPages/subComponents/BatchTable2";
  import BatchTable3 from "@/pages/contents/tracking/BatchParameterPages/subComponents/BatchTable3";
  import BatchProgress from "@/pages/contents/tracking/BatchParameterPages/subComponents/BatchProgress";

  export default {
    name: "BatchParametr",
    components: {
      LeftSideCard,
      BatchTable1,
      BatchTable2,
      BatchTable3,
      BatchProgress,

    },
    data() {
      return {
        areaList: [{
            area: "锅炉房",
            area_value: "157",
            area_unit: "Kg/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "水处理",
            area_value: "3000",
            area_unit: "T/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "空压",
            area_value: "34321",
            area_unit: "nM3/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "CO2",
            area_value: "233",
            area_unit: "nM3/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "制冷",
            area_value: "25",
            area_unit: "HL/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "配电",
            area_value: "343453",
            area_unit: "KWh",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "BTS",
            area_value: "23424",
            area_unit: "T/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "BTS",
            area_value: "23424",
            area_unit: "T/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "BTS",
            area_value: "23424",
            area_unit: "T/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "BTS",
            area_value: "23424",
            area_unit: "T/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "BTS",
            area_value: "23424",
            area_unit: "T/h",
            monitor_value: "15",
            warning_value: "2"
          },
          {
            area: "BTS",
            area_value: "23424",
            area_unit: "T/h",
            monitor_value: "15",
            warning_value: "2"
          }
        ],
        lineList: [{
          line_name: "BL01",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 70,
        }, {
          line_name: "BL02",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 50,
        }, {
          line_name: "BL03",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 60,
        }, {
          line_name: "BL04",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 0,
        }, {
          line_name: "BL05",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 75,
        }, {
          line_name: "CL01",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 55,
        }, {
          line_name: "CL02",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 85,
        }, {
          line_name: "CL03",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 0,
        }, {
          line_name: "KEG01",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 70,
        }, {
          line_name: "KEG02",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 40,
        }, {
          line_name: "KEG03",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 52,
        }, {
          line_name: "KEG01",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 70,
        }, {
          line_name: "KEG02",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 40,
        }, {
          line_name: "KEG03",
          monitor_value: "15",
          warning_value: "2",
          pro_percent: 52,
        }, ]
      };
    },
    methods: {
      toAreaLineOverview() {
        this.$router.push("/area_line_overview");
      }
    }
  };

</script>
<style scoped>
  .main-row {
    height: 99%;
  }

  .leftside-col {
    height: 100%;
    overflow: auto;
  }

  /* .leftside-col:hover {
    overflow-y: auto;
  } */
  .leftside-col::-webkit-scrollbar {
    /*滚动条整体样式*/
    width: 3px;
    /*高宽分别对应横竖滚动条的尺寸*/
    height: 4px;
  }

  .leftside-col::-webkit-scrollbar-thumb {
    /*滚动条里面小方块*/
    border-radius: 5px;
    -webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
    background: rgba(0, 0, 0, 0.2);
  }

  .leftside-col::-webkit-scrollbar-track {
    /*滚动条里面轨道*/
    -webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
    border-radius: 0;
    background: rgba(0, 0, 0, 0.1);
  }

  .leftclass {
    /* height: 100px; */
    /* background-color: white; */
    margin-bottom: 10px;
    /* border-radius: 5px; */
  }

  .rightside-col {
    height: 100%;
    /* background-color: red; */
  }

  .right-buttom-col {
    border-radius: 4px;
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;

  }

  /* .right-buttom-col:hover {
    overflow-y: auto;
  } */
  .right-buttom-col::-webkit-scrollbar {
    /*滚动条整体样式*/
    width: 3px;
    /*高宽分别对应横竖滚动条的尺寸*/
    height: 4px;
    float: right;
  }

  .right-buttom-col::-webkit-scrollbar-thumb {
    /*滚动条里面小方块*/
    border-radius: 5px;
    -webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
    background: rgba(0, 0, 0, 0.2);
  }

  .right-buttom-col::-webkit-scrollbar-track {
    /*滚动条里面轨道*/
    -webkit-box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
    border-radius: 0;
    background: rgba(0, 0, 0, 0.1);
  }

</style>
